package cn.s1995.sloth.bizs.oo.dto;

import cn.s1995.sloth.common.core.convert.JoinUrlPrefixConvert;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.time.LocalDateTime;

/**
 * CartItemDTO
 *
 * @author Lex
 * @description
 * @date 2023/12/25 14:37
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Schema(description = "购物车项")
public class ShopCartItemDTO extends ProductItemDTO {

    @Schema(description = "购物车ID")
    private Long cartId;

    @Schema(description = "店铺ID")
    private Long shopId;

    @Schema(description = "店铺名称")
    private String shopName;

    @Schema(description = "店铺头像")
    @JsonSerialize(using = JoinUrlPrefixConvert.class)
    private String shopAvatar;

    @Schema(description = "产品原价")
    private Double originAmount;

    @Schema(description = "规格名称")
    private String skuName;

    @Schema(description = "推广员使用的推销卡号")
    private String distributionCardNo;

    @Schema(description = "创建时间")
    private LocalDateTime cartTime;

}
